A computing processor typically executes program code found in read-only memory (ROM), random access memory (RAM), or switches on an operator's front panel. Modern operating systems, application code, and data are generally stored on nonvolatile data storage devices, such as hard drives, CDs, DVDs, flash memory cards (like SD cards), USB flash drives, and floppy disks. When an electronic device, such as a computer or set top box is first powered on, it usually does not have an operating system in ROM or RAM. Instead, the device executes a relatively small program (e.g., stored in ROM), along with the bare minimum of data needed to access the nonvolatile devices from which the operating system programs and data may be loaded into RAM. The small program that starts this sequence is generally known as a bootstrap loader, bootstrap or boot loader. The boot loader loads other data and programs which are then executed from RAM. Often, multiple-stage boot loaders are used, during which several programs of increasing complexity load one after the other in a process of chain loading.
Sometimes the boot loader of a device needs replacement. When a single key is used to unlock the device for replacement of the boot loader, once hacked, a hacker can unlock all instances of the device using the hacked key. Unlocking a JTAG (Joint Test Action Group) interface of the device using a password to unlock the boot loader poses a security risk as well. This password is usually recorded per CPUID (central processor unit identifier) and controlled by a chip vendor and is not generally available to a manufacturer. Therefore, there is a long felt need for a secure method of replacing a boot loader of a device.